<%@ page language="java" contentType="text/html;charset=UTF-8" %>
<%@ include file="/static/include/taglib.jsp" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
    <meta name="viewport" content="width=device-width"/>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
    <title>后台管理系统--管理员首页</title>
    <link href="${ctxStatic}/layui/css/layui.css" rel="stylesheet"/>
    <link href="${ctxStatic}/css/kpiui.css" rel="stylesheet"/>
    <link href="${ctxStatic}/css/home.css" rel="stylesheet"/>
    <script src="${ctxStatic}/js/jquery-1.8.3.min.js?v=2.0" type="text/javascript"></script>
    <script src="${ctxStatic}/layui/layui.all.js" type="text/javascript"></script>
    <script src="${ctxStatic}/js/echarts.min.js" type="text/javascript"></script>
    <script src="${ctxStatic}/js/common.js" type="text/javascript"></script>

    <script src="${ctxStatic}/js/adminhome.js?v=<%=System.currentTimeMillis()%>" type="text/javascript"></script>
    <style type="text/css">
        select {
            border: 1px solid #bce5ff;
            outline: none;
            width: 100px;
            height: 25px;
            line-height: 25px;
            appearance: none;
            -webkit-appearance: none;
            -moz-appearance: none;
            padding-left: 6px;
            background-color: rgba(11, 137, 198, 0.81);
            color: #ffffff
        }

        .tiao1 {
            height: 20px;
            width: 2px;
            background-color: #fff;
            margin-right: 5px;
            overflow: hidden;
            margin-left: 15px;
            margin-top: 15px;
            height: 14px;
            display: inline-block;
        }
    </style>
    <style>
        .fangge {
            border: 2px solid #589DF5;
            height: 20px;
            width: 20px;
            line-height: 20px;
            text-align: center;
            display: inline-block
        }

        .jhs {
            color: #FF9926;
            opacity: 0.4;
        }

        .btjhs {
            color: #FF9926;
        }

        .dls {
            color: #00FF2A;
            opacity: 0.4;
        }

        .btdls {
            color: #00FF2A;
        }

        .bmhj table tr {
            height: 30px
        }
    </style>
    <style>
        .layui-table-view .layui-table-header th {
            padding: 0
        }

        .layui-table-view {
            margin: 0 0 10px 0
        }

        .layui-badge-dot {
            position: absolute;
            font-size: 8px;
            width: 13px;
            height: 13px;
            left: 20px
        }

        .number-text {
            position: absolute;
            color: #ffffff;
            font-size: 8px;
            left: 23px;
            display: inline-block;
            top: -5px
        }

        .bcj-text {
            color: #888888;
        }
    </style>
    <style>
        .l-text-field {
            height: 30px
        }
    </style>
</head>
<body>
<!-- <div style="color:#ffffff">
<div class="kpiui-collapse" style="width:65%;float:left;">
 <div class="kpiui-collapse-title"><span class="tiao"></span><span class="navtitle">历年人员评议满意度</span></div>
 <div class="kpiui-collapse-content">
  <div id="Chart" style="height:250px"></div>
 </div>
</div>
<div style="float:right;width:30%;margin-left:10px">
 <div class="seregon">
   <div style="border-radius: 2px;height:100px;color:#ffffff;background:#009688;padding:10px;background-size:100% 100%;position: relative">
   <div>北京-丰台</div>
   <div style="font-size:60pt;position: absolute;top:50%; left:35%;margin-top:-55px">-4</div>
   <div style="font-size:20pt;position: absolute;top:50%; right:30%;margin-top:-55px">o</div>
   <div style="font-size:14pt;position: absolute;top:50%; left:35%;margin-top:25px">多云</div>
  </div>
 </div>
 <div class="seregon" style="margin-top:10px;">
  <div style="color:#ffffff;padding:10px;height:125px;background:#33ab9f;border-radius: 2px;">
    <p style="text-align: center">切实练就拉的出、冲得上、</p>
    <p style="text-align: center">切实练就拉的出、冲得上、</p>
    <p style="text-align: center">切实练就拉的出、冲得上、</p>
  </div>
  </div>
</div>
  <div class="claer"></div>

</div>-->

<!--  <div class="bottom">
 <table>
  <tr>
   <td style="vertical-align: top;width:25%">
    <div class="kpiui-collapse" style="padding:4px 6px 0 3px;">
     <div class="kpiui-collapse-title1"><span class="tiao"></span><span class="navtitle">月度考核准时完成情况</span></div>
     <div class="kpiui-collapse-content">
      <div id="wcl" style="height:140px;"></div>
      <div class="xianshi">45%</div>
     </div>
    </div>
   </td>
   <td style="vertical-align: top;width:25%">
     <div class="kpiui-collapse" style="padding:4px 6px 0 3px;">
     <div class="kpiui-collapse-title1"><span class="tiao"></span><span class="navtitle">月度考核文件归档情况</span></div>
     <div class="kpiui-collapse-content">
      <div style="background-color: #c2c2c2;width:100%;height:60px;margin:45px 0">
       <div style="background-color: #1E9FFF;width:80%;height:100%"></div>
      </div>
      <div class="xianshi">300/400 文件数</div>

     </div>
    </div>
   </td>
   <td style="vertical-align: top;width:25%">
     <div class="kpiui-collapse" style="padding:4px 6px 0 3px;">
     <div class="kpiui-collapse-title1"><span class="tiao"></span><span class="navtitle">民主评议满意度分析</span></div>
     <div class="kpiui-collapse-content">
      <div id="mzpy" style="height:140px;"></div>
      <div class="xianshi">s</div>
     </div>
    </div>
   </td>
   <td style="vertical-align: top;width:25%">
     <div class="kpiui-collapse" style="padding:4px 6px 0 3px;">
     <div class="kpiui-collapse-title1"><span class="tiao"></span><span class="navtitle">考核人员年龄分布情况</span></div>
     <div class="kpiui-collapse-content">
      <div id="nlfb" style="height:140px;"></div>
      <div class="xianshi">s</div>
     </div>
    </div>
   </td>
  </tr>
 </table>
</div>-->

<c:if test="${userhome.userid ==1473}">
    <div style="width:100%;height:100%">
        <div style="float:left;width:50%;height:100%">
            <div style="height:33%">
                <div style="color:#ffffff;height:40px;line-height:40px;background: url(${ctxStatic}/images/title_tb.png) no-repeat;background-size: 30% 100%;">
                    <span class="tiao1"></span>人员情况分析
                </div>
                <div>
                    <table style="width:100%">
                        <tr>
                            <td style="">
                                <div id="ChartAdmin" style="height:150px;color:#ffffff;"></div>
                            </td>
                            <td>
                                <div id="ChartDyAdmin" style="height:150px;color:#ffffff;"></div>
                            </td>
                            <td>
                                <div id="ChartXlAdmin" style="height:150px;color:#ffffff;"></div>
                            </td>
                        </tr>
                    </table>
                </div>
            </div>
            <div style="width:95%;margin-left:0 ">
                <div style="color:#ffffff;height:40px;line-height:40px;background: url(${ctxStatic}/images/title_tb.png) no-repeat;background-size: 30% 100%;">
                    <span class="tiao1"></span>考勤进展情况
                </div>
                <div>
                    <div id="ChartKqjzqkAdmin" style="height:180px;color:#ffffff;width:100%"></div>
                </div>
            </div>
            <div style="width:95%;margin-left:0 ">
                <div style="color:#ffffff;height:40px;line-height:40px;background: url(${ctxStatic}/images/title_tb.png) no-repeat;background-size: 30% 100%;">
                    <span class="tiao1"></span>月末出勤情况
                </div>
                <div>
                    <div id="ChartYmcqqkAdmin" style="height:180px;color:#ffffff;width:100%"></div>
                </div>
            </div>
        </div>
        <div style="float:left;width:50%;height:100%;">
            <div class="kpiui-collapse" style="padding:4px 6px 0 3px;height:47%">
                <div class="kpiui-collapse-title" style="margin: 0px 5px 0 1px;"><span class="tiao"></span><span
                        class="navtitle">公务员平时考核情况</span></div>

                <div class="kpiui-collapse-content" style="width:100%">
                    <div style="height:30px;line-height:30px;color:#ffffff">
                        <img src="${ctxStatic}/images/button/detail.png"
                             style="width:18px;height:20px;vertical-align: middle;margin-right:5px">北京市公安局房山分局公务员平时考核

                        <select id="topquarter" onchange="khjg()" style="float:right;margin:2px 10px 0 0">
                            <option value="1">一季度</option>
                            <option value="2">二季度</option>
                            <option value="3">三季度</option>
                            <option value="4">四季度</option>
                        </select>

                        <select id="topyear" onchange="khjg()" style="float:right;margin:2px 10px 0 0">

                        </select>
                    </div>
                    <iframe id="ikhjg" width="100%" style="min-height: 250px; margin-top: 10px"></iframe>
                </div>
            </div>

            <div class="kpiui-collapse" style="padding:4px 6px 0 3px;height:47%;margin-top:4%;">
                <div class="kpiui-collapse-title" style="margin: 0px 5px 0 1px;"><span class="tiao"></span><span
                        class="navtitle">公务员平时考核情况</span></div>

                <div class="kpiui-collapse-content" style="width:100%;overflow: scroll">
                    <div style="height:30px;line-height:30px;color:#ffffff">
                        <img src="${ctxStatic}/images/button/detail.png"
                             style="width:18px;height:20px;vertical-align: middle;margin-right:5px">北京市公安局房山分局公务员平时考核

                        <select id="bottomquarter" onchange="mzpdChange()" style="float:right;margin:2px 10px 0 0">
                            <option value="1">一季度</option>
                            <option value="2">二季度</option>
                            <option value="3">三季度</option>
                            <option value="4">四季度</option>
                        </select>
                        <input type="hidden" value="${year}" id="hidyear">
                        <input type="hidden" value="${quarter}" id="hidquarter">
                        <select id="bottomyear" onchange="mzpdChange()" style="float:right;margin:2px 10px 0 0">

                        </select>
                    </div>

                    <iframe id="imz" width="100%" style="overflow: scroll;min-height: 462px"></iframe>
                </div>
            </div>

        </div>
    </div>
</c:if>


<c:if test="${userhome.userid !=1473}">

    <div style="width:100%;height:100%">
        <div style="float:left;width:50%;height:100%">
            <div style="height:50%;width:95%;margin-left:0 ">
                <div style="color:#ffffff;height:40px;line-height:40px;background: url(${ctxStatic}/images/title_tb.png) no-repeat;background-size: 30% 100%;">
                    <span class="tiao1"></span>人员情况分析
                </div>
                <div>
                    <table style="width:100%">
                        <tr>
                            <td style="">
                                <div id="Chart" style="height:180px;color:#ffffff;"></div>
                            </td>
                            <td>
                                <div id="ChartDy" style="height:180px;color:#ffffff;"></div>
                            </td>
                            <td>
                                <div id="ChartXl" style="height:180px;color:#ffffff;"></div>
                            </td>
                        </tr>
                    </table>
                </div>
            </div>
            <div style="height:50%;width:95%;margin-left:0 ">
                <div style="color:#ffffff;height:40px;line-height:40px;background: url(${ctxStatic}/images/title_tb.png) no-repeat;background-size: 30% 100%;">
                    <span class="tiao1"></span>月末出勤情况
                </div>
                <div>
                    <div id="ChartYmcqqk" style="height:180px;color:#ffffff;width:100%"></div>
                </div>
            </div>
        </div>
        <div style="float:left;width:50%;height:100%;">
            <div class="kpiui-collapse" style="padding:4px 6px 0 3px;height:100%">
                <div class="kpiui-collapse-title" style="margin: 0px 5px 0 1px;"><span class="tiao"></span><span
                        class="navtitle">公务员平时考核情况</span></div>

                <div class="kpiui-collapse-content" style="width:97%">
                    <!-- style="background: url(${ctxStatic}/images/index/formbg.png);width:97%" -->
                    <div style="height:30px;line-height:30px;color:#ffffff">
                        <img src="${ctxStatic}/images/button/detail.png"
                             style="width:18px;height:20px;vertical-align: middle;margin-right:5px">北京市公安局房山分局公务员平时考核

                        <select id="quarter" style="float:right;margin:2px 10px 0 0" onchange="searchtable(1)">
                            <option value="1">一季度</option>
                            <option value="2">二季度</option>
                            <option value="3">三季度</option>
                            <option value="4">四季度</option>
                        </select>

                        <select id="year" style="float:right;margin:2px 10px 0 0" onchange="searchtable(0)">
                            <option value="2019">2019年</option>
                            <option value="2018">2018年</option>
                            <option value="2017">2017年</option>
                            <option value="2016">2016年</option>
                        </select>
                    </div>

                    <div>
                        <table class="layui-table" lay-data="" lay-filter="summarylist">
                            <thead>
                            <tr>
                                <th lay-data="{field:'realname', width:'20%',align:'center'}" rowspan="2">姓名</th>
                                <th lay-data="{align:'center'}" colspan="3" id="thjd">第一季度</th>
                            </tr>
                            <tr>
                                <th lay-data="{field:'zhdf', width:'20%',align:'center',style:'color: #FCFF04;',event:'glxs'}">
                                    综合评分
                                </th>
                                <th lay-data="{field:'zzpdjg', width:'30%',align:'center',style:'color: #FCFF04;',event:'glxs'}">
                                    组织评定
                                </th>
                                <th lay-data="{field:'dymzpyjg', width:'30%',align:'center',style:'color: #FCFF04;',event:'glxs'}">
                                    民主评定
                                </th>
                            </tr>
                            </thead>
                        </table>
                    </div>
                </div>
            </div>
        </div>
    </div>
</c:if>
<!--  <div class="bottom">
  <ul>
   <li style="position: relative">
     <div id="wcl" style="height:100%;width:100%"></div>
     <div style="position:absolute;bottom:10px;">
      <span style="font-size:24px;">80</span>
      <br/>
      <span style="font-size:12px;color:#c2c2c2">上个月数据分析</span>
     </div>

     <div style="position:absolute;color:orange;top:30px;left:30px;font-size:24px;">
      60
     </div>
      <div class="claer"></div>
   </li>
   <li>
    <div style="padding:10px">
     <h2 style="font-size:14px;color:#c2c2c2;text-align: center">月度考核文件归档情况</h2>
     <div style="background-color: #c2c2c2;width:100%;height:80px;margin:10px 0">
      <div style="background-color: #1E9FFF;width:80%;height:100%"></div>
     </div>
     <div style="width:100%;text-align: center;font-size:24px;">300/400</div>
     <div style="color:#1E9FFF;width:100%;text-align: center;font-size:20px;margin-top:10px">文件数</div>
    </div>
   </li>

   <li>
    <div id="mzpy" style="height:100%;width:100%"></div>
   </li>

   <li>
    <div id="nlfb" style="height:100%;width:100%"></div>
   </li>

  </ul>

</div>-->

<input type="hidden" id="hiduserid" value="${userhome.userid }"/>

<script>
    var year = new Date().getFullYear();
    $(function () {
        getYearData("topyear");
        getYearData("bottomyear");

        var quarter = getQuarter();//初始化年
        $('#topyear').val(year);
        $('#bottomyear').val(year);
        $('#topquarter').val(quarter);
        $('#bottomquarter').val(quarter);
        $('#ikhjg').attr('src', 'statistics/peacetime?year=' + year + "&quarter=" + quarter);
        $('#imz').attr("src", 'useruatmzpdSeason/usualass_mzpd_season_list_admin?year=' + year + "&quarter=" + quarter)


    })

    function getQuarter() {
        var month = new Date().getMonth();
        if (month < 3) {
            year = new Date().getFullYear() - 1;
            return '4';
        } else if (month < 6) {
            return '1';
        } else if (month < 9) {
            return '2';
        } else if (month < 12) {
            return '3';
        }
    }

    function khjg() {


        var year = $('#topyear').val();
        var quarter = $('#topquarter').val();
        $('#ikhjg').attr('src', 'statistics/peacetime?year=' + year + "&quarter=" + quarter);
    }

    function mzpdChange() {

        var year = $('#bottomyear').val();
        var quarter = $('#bottomquarter').val();
        $('#imz').attr("src", 'useruatmzpdSeason/usualass_mzpd_season_list_admin?year=' + year + "&quarter=" + quarter)
    }
</script>

</body>
</html>